<!--#include("header.html")-->
<!--%import("js/toggle.js")-->
<!-- #issueBody -->
<div id="issueBody">
<!-- #pxeContent -->
<div id="pxeContent">

<div class="pxeHeading">
	<h2>다운로드</h2>
</div>

<span class="pxeDownloadHr"></span>
<!--@if(count($package_list) == 0)-->
<div class="pxeNews pxeNoData">
<p>아직 올라온 패키지가 없습니다.</p>
</div>
<!--@else-->
<!--@foreach($package_list as $key => $val)-->
<div class="pxeDownload">
	<div class="dHeader">
		<h3>{$val->title}</h3>
		<p>{nl2br($val->description)}</p>
	</div>

<!--@if(count($val->releases))-->
	<!--@foreach($val->releases as $k => $v)-->
	{@ $sumDownload = 0; }
	<!--@if($v->files)-->
	<!--@foreach($v->files as $file)-->
		{@ $sumDownload += $file->download_count }
	<!--@endforeach-->
	<!--@endif-->
	<div class="dBody show">
		<div class="vTitle">
			<h4>{$v->title}</h4>
			<table border="1" cellspacing="0" summary="Distribution Information">
				<tr>
					<th scope="row">배포 날짜</th>
					<td>{zdate($v->regdate, "Y.m.d")}</td>
				</tr>
				<tr>
					<th scope="row">다운로드</th>
					<td>{$sumDownload}</td>
				</tr>
			</table>
		</div>

		<div class="vContent">

			<table border="1" cellspacing="0" summary="Programe Information">
			<tr>
				<th scope="col">다운로드</th>
				<th scope="col" class="desc">설명</th>
				<th scope="col">크기</th>
				<th scope="col">다운로드</th>
			</tr>
			<!--@if($v->files)-->
			<!--@foreach($v->files as $file)-->
			<tr>
				<td><a href="{$file->download_url}">{$file->source_filename}</a></td>
				<td class="desc">{nl2br($file->comment)}</td>
				<td class="num">{FileHandler::filesize($file->file_size)}</td>
				<td class="num">{$file->download_count}</td>
			</tr>
			<!--@endforeach-->
			<!--@else-->
			<tr>
				<td colspan="4">
				<div class="pxeNoData">아직 등록된 파일이 없습니다.</div>
			</tr>
			<!--@end-->

			</table>

			<!--@if($v->release_note || $v->release_changes)-->
			<div class="vInfo openInfo">
				<button type="button"><span class="opener">배포기록 및 변경사항</span> <span class="closer">닫기</span> <span class="i"></span></button>
				<dl>
				<!--@if($v->release_note)-->
				<dt>배포기록</dt>
				<dd>{nl2br($v->release_note)}</dd>
				<!--@end-->
				<!--@if($v->release_changes)-->
				<dt>변경사항</dt>
				<dd>{nl2br($v->release_changes)}</dd>
				<!--@end-->
				</dl>
			</div> <!--/vInfo-->
			<!--@endif-->
		</div> <!--/vContent-->
	</div> <!--/dBody-->
	<!--@endforeach-->
	<!--@if(count($val->releases) > 1)-->
	<div class="dFooter">
		<div class="fRight">
			<span class="btnPxe strong"><button type="button" class="hidden"><span class="opener">지난버전 모두보기</span> <span class="closer">지난버전 숨기기</span> <span class="i"></span></button></span>
		</div>
	</div>
	<!--@endif-->
<!--@else-->
<div class="pxeNews pxeNoData">
<p>아직 등록된 배포본이 없습니다.</p>
</div>
<!--@endif-->
</div>
<!--@end-->

<!--@end-->
</div>
</div>
	

<!--#include("footer.html")-->
